<!--
  - login.php
  - v0.03
  - 3/20/2011
  - 
  - This source code generates the user interface for logging in. 
  -->
<?php 
	if(isset($_SESSION["analyst"]) || isset($_SESSION["administrator"])){
		session_destroy();
	}
?>
<html>
	<head>
		<title>CASLIMS</title>
		<link rel="stylesheet" type="text/css" href="scripts/login.css" />
		<script type="text/javascript" src="scripts/validateLogin.js"></script>
		<link href="tools/favicon.ico" rel="shortcut icon" type="image/x-icon" /> 
	</head>
	<body>		
		<div id="header"><img src="tools/header.png" width="594" height="60" /></div>		
		<div id="container">
			<form name = "login" action="ProcessLogin.php" method = "post"  onsubmit = "return validateLogin()" >
				<div id="loginlabel">Log In</div>
				<table>
					<tr>
						<td><div id=label>Username</div></td>
						<td><input type = "text" name = "username" id = "username" maxlength = "30" /></td>
					</tr>
					<tr>
						<td><div id=label>Password</div></td>
						<td><input type = "password" name = "password" id = "password" maxlength = "30" /></td>
					</tr>
					<tr>
						<td></td>
						<td><div id = "errorLogin"><?php if(isset($_GET["error"]))echo "Invalid username/password";?><br/></div></td>
					</tr>
					<tr>
						<td><input type = "submit" value = "Log In" /></td>
					</tr>
				</table>
			</form>
		</div>			
		<div id="footer"> 
				<div class="copyright">Copyright 2011.<a>CASL BIOTECH-UPLB.</a> All Rights Reserved.<br/> 
				Arianne Buse&ntilde;os | Darlene Joy Masong | Rick Jason Obrero | Jonathan Pandi | Jonathan Simbahan | Emmanuel Soriano 
					</div> 
	    </div>
	</body>
</html>